package cn.jb698.codec.msm.generator.v5base.req;

import java.sql.Connection;

/**
 * 请求Bean
 */
public class BcrudCreateJsonCreateTableJsonBeanReq {

	private Connection connection; // 数据库连接
	private String tableName; // 表名称
	private String projPackage; // 项目层包名
	private String basePackage; // 基础包名
	private String tableAlias; // 表别名
	private String modelJavaTypeName; // JavaBean类名称
	private String[] primKeyColumns; // 主键
	private String[] ignoreColumns; // 忽略的字段
	private boolean hasSwaggerUi; // 是否生成SwaggerUi注解
	private boolean hasPersistence; // 是否生成persistence注解
	private boolean hasBaomidou; // 是否生成baomidou注解
	private boolean hasAutoCutLengh; // 是否自动剪切字符串长度

	public Connection getConnection() {
		return connection;
	}

	public void setConnection(Connection connection) {
		this.connection = connection;
	}

	public String getTableName() {
		return tableName;
	}

	public void setTableName(String tableName) {
		this.tableName = tableName;
	}

	public String getBasePackage() {
		return basePackage;
	}

	public void setBasePackage(String basePackage) {
		this.basePackage = basePackage;
	}

	public String getTableAlias() {
		return tableAlias;
	}

	public void setTableAlias(String tableAlias) {
		this.tableAlias = tableAlias;
	}

	public String getModelJavaTypeName() {
		return modelJavaTypeName;
	}

	public void setModelJavaTypeName(String modelJavaTypeName) {
		this.modelJavaTypeName = modelJavaTypeName;
	}

	public String[] getPrimKeyColumns() {
		return primKeyColumns;
	}

	public void setPrimKeyColumns(String[] primKeyColumns) {
		this.primKeyColumns = primKeyColumns;
	}

	public String[] getIgnoreColumns() {
		return ignoreColumns;
	}

	public void setIgnoreColumns(String[] ignoreColumns) {
		this.ignoreColumns = ignoreColumns;
	}

	public boolean isHasSwaggerUi() {
		return hasSwaggerUi;
	}

	public void setHasSwaggerUi(boolean hasSwaggerUi) {
		this.hasSwaggerUi = hasSwaggerUi;
	}

	public boolean isHasPersistence() {
		return hasPersistence;
	}

	public void setHasPersistence(boolean hasPersistence) {
		this.hasPersistence = hasPersistence;
	}

	public boolean isHasAutoCutLengh() {
		return hasAutoCutLengh;
	}

	public void setHasAutoCutLengh(boolean hasAutoCutLengh) {
		this.hasAutoCutLengh = hasAutoCutLengh;
	}

	public String getProjPackage() {
		if(projPackage == null && basePackage != null ) {
			projPackage = basePackage + ".ctrler";
		}
		return projPackage;
	}

	public void setProjPackage(String ctrlerPackage) {
		this.projPackage = ctrlerPackage;
	}

	public boolean isHasBaomidou() {
		return hasBaomidou;
	}

	public void setHasBaomidou(boolean hasBaomidou) {
		this.hasBaomidou = hasBaomidou;
	}
	
	
}
